﻿using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class UIManager : MonoBehaviour
{

    public static UIManager instance;


    public void Awake()
    {
        instance = this;
    }


    public void ShowPanel(string name,Transform parent)
    {
        var prefab = Resources.Load<GameObject>(name);

        GameObject.Instantiate(prefab,parent);
    }


    public void HidePanel(string name)
    {
        GameObject.Find(name).gameObject.SetActive(false);
    }


}
